
* Filepath to output folder ( <directory>/calibration/output )
global outputfilepath = "<REPLICATION PACKAGE FOLDER HERE>/calibration/output"

clear all




input sigma varepsilon09 varepsilon47 varepsilon76
	0		.			.			.		.			.
0.0150000000000000	-0.339492375932872	-0.966130253125220	-0.843166366369648
0.0200000000000000	-0.254027986542153	-0.910734512045437	-0.910185104257478
0.0250000000000000	-0.201822007173196	-0.814131933364124	-0.931233409709409
0.0300000000000000	-0.166713216151044	-0.716345955729518	-0.912883241954518
0.0350000000000000	-0.141509444971011	-0.630539839299773	-0.869327315611906
0.0400000000000000	-0.122546002719243	-0.558423149674827	-0.813693570676479
0.0450000000000000	-0.107764249193027	-0.498343910610802	-0.754817151138531
0.0500000000000000	-0.0959200997776064	-0.448101118383721	-0.697578351853273
0.0550000000000000	-0.0862179147691642	-0.405732143895672	-0.644235859827482
0.0600000000000000	-0.0781253413426082	-0.369656935173467	-0.595573032160796
0.0610000000000000	-0.0766653391478315	-0.363083391564379	-0.586413141445526
0.0620000000000000	-0.0752522397762400	-0.356703051367842	-0.577441161327214
0.0630000000000000	-0.0738838208734956	-0.350507950624503	-0.568654855857159
0.0630300000000000	-0.0738434364965222	-0.350324879477552	-0.568394109216534
0.0630500000000000	-0.0738165348444630	-0.350202920769088	-0.568220369648308
0.0640000000000000	-0.0725579981971091	-0.344490523391862	-0.560051651344617
0.0650000000000000	-0.0712728150598775	-0.338643580558752	-0.551628698246303
0.0660000000000000	-0.0700264327262361	-0.332960289574426	-0.543382924863137
0.0670000000000000	-0.0688171216627474	-0.327434155116806	-0.535311083825558
0.0680000000000000	-0.0676432535554618	-0.322059000705964	-0.527409792242513
0.0690000000000000	-0.0665032940169129	-0.316828951255109	-0.519675566291608
0.0700000000000000	-0.0653957959143012	-0.311738416541227	-0.512104850940062
0.0701000000000000	-0.0652867782204288	-0.311236829270661	-0.511356634131470
0.0702000000000000	-0.0651780700956314	-0.310736578550188	-0.510610012821593
0.0703000000000000	-0.0650696702242826	-0.310237659227592	-0.509864983389362
0.0704000000000000	-0.0649615772981961	-0.309740066175817	-0.509121542211768
0.0705000000000000	-0.0648537900165708	-0.309243794292796	-0.508379685664015
0.0707000000000000	-0.0646391272201380	-0.308255193748992	-0.506900711951259
0.0710000000000000	-0.0643193932580132	-0.306782075569804	-0.504694045405803
0.0720000000000000	-0.0632727955963969	-0.301954861803122	-0.497439524897009
0.0730000000000000	-0.0622547828685502	-0.297251949217861	-0.490337659104015
0.0740000000000000	-0.0612642006720760	-0.292668739155631	-0.483384827860697
0.0750000000000000	-0.0602999559073213	-0.288200847928945	-0.476577434341813
0.0770000000000000	-0.0584463890167086	-0.279594492707447	-0.463384754349816
0.0800000000000000	-0.0558393456899862	-0.267451377770335	-0.444599022849719
0.0810000000000000	-0.0550131346099575	-0.263593991835993	-0.438591207607949
0.0811000000000000	-0.0549316312843349	-0.263213240713033	-0.437997168474340
0.0812000000000000	-0.0548503281983200	-0.262833383908221	-0.437404342471586
0.0813000000000000	-0.0547692246154468	-0.262454418343106	-0.436812726433338
0.0814000000000000	-0.0546883198028553	-0.262076340952949	-0.436222317200459
0.0815000000000000	-0.0546076130312688	-0.261699148686636	-0.435633111621023
0.0816000000000000	-0.0545271035749720	-0.261322838506617	-0.435045106550343
0.0817000000000000	-0.0544467907117905	-0.260947407388830	-0.434458298850995
0.0818000000000000	-0.0543666737230670	-0.260572852322623	-0.433872685392810
0.0819000000000000	-0.0542867518936412	-0.260199170310689	-0.433288263052907
0.0820000000000000	-0.0542070245118310	-0.259826358369004	-0.432705028715717
0.0830000000000000	-0.0534202911855168	-0.256145445679304	-0.426937345308991
0.0840000000000000	-0.0526522447837610	-0.252548353473041	-0.421285089681220
0.0850000000000000	-0.0519022278087869	-0.249032306066763	-0.415745268315400
0.0860000000000000	-0.0511696132387974	-0.245594645996033	-0.410314962432849
0.0870000000000000	-0.0504538027831340	-0.242232827994144	-0.404991328131375
0.0880000000000000	-0.0497542252559086	-0.238944413318094	-0.399771596176030
0.0890000000000000	-0.0490703350588301	-0.235727064400334	-0.394653071497484
0.0900000000000000	-0.0484016107647734	-0.232578539806148	-0.389633132445713
0.100000000000000	-0.0424486490578021	-0.204445483407946	-0.344329374671959
0.110000000000000	-0.0375764374399648	-0.181289612560318	-0.306495479241246
0.120000000000000	-0.0335153223070857	-0.161907646525906	-0.274500795199273
0.130000000000000	-0.0300784557075913	-0.145452345767188	-0.247131842128976
0.140000000000000	-0.0271322806175587	-0.131310915691810	-0.223477037939471
0.150000000000000	-0.0245787987205214	-0.119029653797636	-0.202842906521554
0.160000000000000	-0.0223444760114285	-0.108265721466183	-0.184694781037029
0.170000000000000	-0.0203730578244360	-0.0987553685700484	-0.168614978259499
0.180000000000000	-0.0186207753760345	-0.0902924490622621	-0.154273105559925
0.190000000000000	-0.0170530640182304	-0.0827135548426407	-0.141404756988229
0.200000000000000	-0.0156422648081399	-0.0758875139356536	-0.129796040720445
0.210000000000000	-0.0143659820249855	-0.0697078324086845	-0.119272199090058
0.220000000000000	-0.0132058881621809	-0.0640871628053036	-0.109689134021761
0.230000000000000	-0.0121468403513857	-0.0589531937124576	-0.100927020193257
0.240000000000000	-0.0111762174747274	-0.0542455528312472	-0.0928854366602706
0.250000000000000	-0.0102834162303699	-0.0499134440201468	-0.0854796160117603
0.260000000000000	-0.00945946339408910	-0.0459138233945977	-0.0786375253461865
0.270000000000000	-0.00869671417712225	-0.0422099764689736	-0.0722975731046449
0.280000000000000	-0.00798861517326671	-0.0387703972286753	-0.0664067916151839
0.290000000000000	-0.00732951631645601	-0.0355678970234053	-0.0609193847150462
0.300000000000000	-0.00671452042123812	-0.0325788901824318	-0.0557955580958206
0.310000000000000	-0.00613936182550503	-0.0297828168109200	-0.0510005704699323
0.320000000000000	-0.00560030777352567	-0.0271616730145355	-0.0465039586015194
0.330000000000000	-0.00509407771860948	-0.0246996259462505	-0.0422789002705459
0.340000000000000	-0.00461777685828772	-0.0223826963427584	-0.0383016874488939
0.350000000000000	-0.00416884105715667	-0.0201984951477583	-0.0345512881341175
0.360000000000000	-0.00374499094434925	-0.0181360037752114	-0.0310089799576993
0.370000000000000	-0.00334419345082875	-0.0161853898083444	-0.0276580422508981
0.380000000000000	-0.00296462941671967	-0.0143378516457115	-0.0244834959944591
0.390000000000000	-0.00260466617972830	-0.0125854869281327	-0.0214718832037675
0.400000000000000	-0.00226283427338609	-0.0109211806073053	-0.0186110789587586
0.420000000000000	-0.00162838604685007	-0.00783165936260529	-0.0132991195551041
0.440000000000000	-0.00105210437959237	-0.00502480275543276	-0.00847170761556783
0.460000000000000	-0.000526404908897389	-0.00246383870678783	-0.00406603488047828
0.480000000000000	-4.49668886869893e-05	-0.000118106479605624	-2.96881700990575e-05
0.500000000000000	0.000397519446467610	0.00203816193541131	0.00368141369481757
0.520000000000000	0.000805547236614350	0.00402678009796418	0.00710461084579574
0.540000000000000	0.00118294417569465	0.00586633750191166	0.0102717424963138
0.560000000000000	0.00153299130534986	0.00757277387904224	0.0132101232269711
0.580000000000000	0.00185851723803245	0.00915983498913640	0.0159433186233524
0.600000000000000	0.00216197354089503	0.0106394374748186	0.0184917667496437
0.620000000000000	0.00244549553326610	0.0120219632626119	0.0208732800369621
0.640000000000000	0.00271095168762280	0.0133164988848288	0.0231034535822411
0.660000000000000	0.00295998405086396	0.0145310313790574	0.0251959995934699
0.680000000000000	0.00319404153417848	0.0156726096857486	0.0271630231024384
0.700000000000000	0.00341440749743974	0.0167474784300227	0.0290152506302202
0.720000000000000	0.00362222273726222	0.0177611894468520	0.0307622209083308
0.740000000000000	0.00381850474809850	0.0187186952524051	0.0324124448006397
0.760000000000000	0.00400416394276943	0.0196244277812638	0.0339735400743665
0.780000000000000	0.00418001737805263	0.0204823650295371	0.0354523455153326
0.800000000000000	0.00434680042185407	0.0212960877168342	0.0368550179876637
0.800000000000000	0.00434680042185407	0.0212960877168342	0.0368550179876637
0.900000000000000	0.00506582286608294	0.0248045535640490	0.0429036618710228
1	0.00563548423514669	0.0275846661447887	0.0476975472465300
1.10000000000000	0.00609652142207105	0.0298349412179746	0.0515783739084829

end

global coef = -26.18/100 /* Divide by 100 to get effect of 1 pp shock */
global coef_lb = (-26.18-1.96*4.12)/100
global coef_ub = (-26.18+1.96*4.12)/100 

capture drop coef*
gen coef = $coef
gen coef_lb = $coef_lb
gen coef_ub = $coef_ub

*0.0815 rounds down (0.081)
set scheme s2mono, permanently
#delimit;
			twoway 	( line varepsilon09 sigma if sigma>=0.01, lcolor(blue%25)  lpattern(longdash) ) 
					( line varepsilon47 sigma if sigma>0.05, lcolor(blue)  lpattern(solid)  lwidth(medthick) ) 
					( line varepsilon76 sigma if inrange(sigma,0.071,0.11), lcolor(blue%20) lpattern(dash)  ) 
					( line varepsilon76 sigma if inrange(sigma,0.14,.), lcolor(blue%20) lpattern(dash)  ) 
					( line coef sigma , lcolor(gray%80) lpattern(longdash) lwidth(medthick)  ) 
					( rarea coef_ub coef_lb sigma , color(gray%10) lcolor(white%0)  ) 
					( scatteri -0.2618 0.0815, msymbol(o) color(blue) msize(medium))
					,
					graphregion(color(white))
					ylabel(-0.5(0.1)0.2 , /*glcolor(gs15) gmax gmin*/ nogrid)
					xlabel(0(0.25)1.10, nogrid glcolor(gs15))
					plotregion(margin(miniscule))
					xmtick(0(0.05)1.10)
					legend(order( 
									1 "{stSerif:{&epsilon} = 0.09 }"
									2 "{stSerif:{&epsilon} = 0.44 (main estimate)}"
									3 "{stSerif:{&epsilon} = 0.88 }" 
									 )
									 
						   rows(4) cols(1) size(medsmall) region(color(white%0) ) ring(0) pos(11) margin(0 3 0 0) bmargin(1 0 0 0) )
				
					text(  -0.23 0.6 "{stSerif: Empirical estimate with 95% CI}", place(e) color(gray))
					text(  -0.28 0.0815 "{stSerif: EIS = 0.0815}", place(e) color(blue%80))
					xtitle("{stSerif:Elasticity of Intertemporal Substitution,  {&sigma}}")
					ytitle("{stSerif:Log-change in Charitable Giving}")
					/*subtitle("{stSerif:`title'}", color(black))*/;
			#delimit cr
graph export ${outputfilepath}/wdon1_calibration_Dlog_g_sigma.pdf, as(pdf) replace






* Show how MPG varies with EIS for different kappas [**]

clear
input sigma kappanorway kappahigh
0 . .
0.01 . .
0.02 . .
0.03 . .
0.04 . .
0.05 . .
0.08 . .
0.09 . .
0.0200000000000000	-0.460969370116007	-0.630328092663650
0.0225000000000000	-0.411667639492894	-0.612229163858849
0.0250000000000000	-0.366898243126909	-0.594338571621091
0.0275000000000000	-0.326972627934908	-0.576709676667919
0.0300000000000000	-0.291815797141122	-0.559388708833917
0.0325000000000000	-0.261110229809379	-0.542414921151328
0.0350000000000000	-0.234414696026388	-0.525820878897086
0.0375000000000000	-0.211247598911879	-0.509632851866910
0.0400000000000000	-0.191138133891863	-0.493871279944058
0.0425000000000000	-0.173653478554995	-0.478551285032114
0.0450000000000000	-0.158410249637043	-0.463683206130812
0.0475000000000000	-0.145076636868191	-0.449273138343022
0.0500000000000000	-0.133369574994152	-0.435323460581090
0.0525000000000000	-0.123049662337451	-0.421833340473314
0.0550000000000000	-0.113915383392597	-0.408799208302174
0.0575000000000000	-0.105797459989008	-0.396215194666490
0.0600000000000000	-0.0985537182486316	-0.384073528922890
0.0625000000000000	-0.0920646124297395	-0.372364897346930
0.0650000000000000	-0.0862294170160043	-0.361078761397976
0.0675000000000000	-0.0809630362761747	-0.350203637534328
0.0700000000000000	-0.0761933559001254	-0.339727340757436
0.0705000000000000	-0.0752934592086359	-0.337678831652188
0.0710000000000000	-0.0744105048052631	-0.335645666332773
0.0750000000000000	-0.0679078128953936	-0.319920209999623
0.0760000000000000	-0.0664243101635766	-0.316134958294789
0.0770000000000000	-0.0649922848367046	-0.312406464241480
0.0780000000000000	-0.0636093149614187	-0.308733883561506
0.0790000000000000	-0.0622731181182218	-0.305116373364001
0.0800000000000000	-0.0609815421415077	-0.301553093113444
0.0810000000000000	-0.0597325565219910	-0.298043205521002
0.0811000000000000	-0.0596099256878676	-0.297695121239531
0.0812000000000000	-0.0594876996448697	-0.297347561717704
0.0813000000000000	-0.0593658765469353	-0.297000526125224
0.0814000000000000	-0.0592444545585037	-0.296654013632351
0.0850000000000000	-0.0551257350610497	-0.284520993622213
0.0860000000000000	-0.0540629750239903	-0.281265677297851
0.0870000000000000	-0.0530327690157044	-0.278058839428394
0.0880000000000000	-0.0520337445199238	-0.274899684851631
0.0890000000000000	-0.0510646008768664	-0.271787426508439
0.0900000000000000	-0.0501241048730929	-0.268721285817380
0.0910000000000000	-0.0492110866366063	-0.265700493008045
0.0920000000000000	-0.0483244358140240	-0.262724287415432
0.0930000000000000	-0.0474630980086794	-0.259791917738525
0.0940000000000000	-0.0466260714600027	-0.256902642264864
0.0950000000000000	-0.0458124039463196	-0.254055729064022
0.0960000000000000	-0.0450211898944068	-0.251250456151510
0.0970000000000000	-0.0442515676806829	-0.248486111625836
0.0980000000000000	-0.0435027171099399	-0.245761993780087
0.0990000000000000	-0.0427738570587413	-0.243077411190347
0.100000000000000	-0.0420642432715644	-0.240431682782344
0.101000000000000	-0.0413731662987004	-0.237824137877973
0.102000000000000	-0.0406999495658656	-0.235254116223752
0.103000000000000	-0.0400439475660666	-0.232720968001688
0.104000000000000	-0.0394045441652266	-0.230224053824927
0.105000000000000	-0.0387811510135269	-0.227762744718828
0.106000000000000	-0.0381732060551637	-0.225336422088784
0.107000000000000	-0.0375801721297121	-0.222944477676203
0.108000000000000	-0.0370015356587801	-0.220586313503132
0.109000000000000	-0.0364368054122343	-0.218261341807271
0.110000000000000	-0.0358855113484830	-0.215968984967466
0.111000000000000	-0.0353472035239698	-0.213708675421274
0.112000000000000	-0.0348214510671653	-0.211479855574846
0.113000000000000	-0.0343078412128383	-0.209281977706332
0.114000000000000	-0.0338059783926183	-0.207114503863118
0.115000000000000	-0.0333154833781631	-0.204976905753838
0.116000000000000	-0.0328359924735380	-0.202868664635650
0.117000000000000	-0.0323671567536015	-0.200789271197159
0.118000000000000	-0.0319086413455055	-0.198738225438038
0.119000000000000	-0.0314601247505104	-0.196715036545172
0.120000000000000	-0.0310212982035972	-0.194719222766258
0.121000000000000	-0.0305918650685222	-0.192750311281026
0.122000000000000	-0.0301715402660877	-0.190807838070746
0.123000000000000	-0.0297600497335403	-0.188891347785821
0.124000000000000	-0.0293571299132984	-0.187000393612644
0.125000000000000	-0.0289625272690635	-0.185134537139094
0.126000000000000	-0.0285759978277869	-0.183293348219718
0.127000000000000	-0.0281973067458752	-0.181476404840349
0.128000000000000	-0.0278262278981824	-0.179683292982649
0.129000000000000	-0.0274625434884792	-0.177913606488813
0.130000000000000	-0.0271060436800778	-0.176166946926373
0.131000000000000	-0.0267565262454721	-0.174442923453555
0.132000000000000	-0.0264137962338802	-0.172741152685349
0.133000000000000	-0.0260776656556416	-0.171061258560139
0.134000000000000	-0.0257479531825144	-0.169402872207448
0.135000000000000	-0.0254244838629544	-0.167765631816520
0.136000000000000	-0.0251070888515542	-0.166149182506257
0.137000000000000	-0.0247956051518035	-0.164553176196133
0.138000000000000	-0.0244898753714734	-0.162977271478751
0.139000000000000	-0.0241897474898885	-0.161421133493545
0.140000000000000	-0.0238950746364285	-0.159884433801982
0.141000000000000	-0.0236057148797026	-0.158366850264550
0.142000000000000	-0.0233215310267279	-0.156868066919019
0.143000000000000	-0.0230423904316381	-0.155387773860573
0.144000000000000	-0.0227681648133945	-0.153925667123541
0.145000000000000	-0.0224987300819777	-0.152481448564754
0.146000000000000	-0.0222339661726909	-0.151054825748853
0.147000000000000	-0.0219737568880750	-0.149645511835215
0.148000000000000	-0.0217179897470532	-0.148253225466647
0.149000000000000	-0.0214665558409670	-0.146877690659980
0.150000000000000	-0.0212193496961073	-0.145518636698488
0.151000000000000	-0.0209762691424002	-0.144175798025942
0.152000000000000	-0.0207372151879824	-0.142848914142692
0.153000000000000	-0.0205020918993164	-0.141537729503471
0.154000000000000	-0.0202708062865889	-0.140241993417001
0.155000000000000	-0.0200432681941403	-0.138961459947507
0.156000000000000	-0.0198193901956336	-0.137695887817889
0.157000000000000	-0.0195990874937769	-0.136445040314812
0.158000000000000	-0.0193822778243351	-0.135208685195495
0.159000000000000	-0.0191688813642623	-0.133986594596397
0.160000000000000	-0.0189588206436958	-0.132778544943412
0.161000000000000	-0.0187520204617011	-0.131584316864117
0.162000000000000	-0.0185484078054994	-0.130403695101402
0.163000000000000	-0.0183479117731134	-0.129236468429122
0.164000000000000	-0.0181504634991565	-0.128082429569111
0.165000000000000	-0.0179559960837287	-0.126941375110170
0.166000000000000	-0.0177644445241754	-0.125813105428386
0.167000000000000	-0.0175757456496542	-0.124697424609321
0.168000000000000	-0.0173898380583140	-0.123594140371581
0.169000000000000	-0.0172066620570296	-0.122503063992122
0.170000000000000	-0.0170261596035125	-0.121424010232937
0.171000000000000	-0.0168482742507401	-0.120356797269402
0.172000000000000	-0.0166729510935718	-0.119301246620053
0.173000000000000	-0.0165001367174446	-0.118257183077763
0.174000000000000	-0.0163297791490975	-0.117224434642487
0.175000000000000	-0.0161618278091884	-0.116202832455381
0.176000000000000	-0.0159962334667275	-0.115192210734178
0.177000000000000	-0.0158329481952906	-0.114192406710187
0.178000000000000	-0.0156719253308640	-0.113203260566393
0.179000000000000	-0.0155131194313178	-0.112224615377044
0.180000000000000	-0.0153564862373884	-0.111256317048424
0.181000000000000	-0.0152019826351215	-0.110298214260890
0.182000000000000	-0.0150495666197284	-0.109350158412271
0.183000000000000	-0.0148991972607718	-0.108412003562307
0.184000000000000	-0.0147508346686394	-0.107483606378488
0.185000000000000	-0.0146044399622440	-0.106564826082872
0.186000000000000	-0.0144599752378953	-0.105655524400139
0.187000000000000	-0.0143174035393127	-0.104755565506792
0.188000000000000	-0.0141766888287102	-0.103864815981391
0.189000000000000	-0.0140377959589156	-0.102983144755899
0.190000000000000	-0.0139006906465010	-0.102110423068147
0.191000000000000	-0.0137653394458390	-0.101246524415135
0.192000000000000	-0.0136317097241050	-0.100391324507627
0.193000000000000	-0.0134997696371318	-0.0995447012254765
0.194000000000000	-0.0133694881061174	-0.0987065345740496
0.195000000000000	-0.0132408347951499	-0.0978767066415872
0.196000000000000	-0.0131137800894895	-0.0970551015574821
0.197000000000000	-0.0129882950746222	-0.0962416054514663
0.198000000000000	-0.0128643515159997	-0.0954361064136365
0.199000000000000	-0.0127419218394994	-0.0946384944554654
0.200000000000000	-0.0126209791125167	-0.0938486614714777
0.201000000000000	-0.0125014970257227	-0.0930665012020114
0.202000000000000	-0.0123834498754029	-0.0922919091964894
0.203000000000000	-0.0122668125464143	-0.0915247827777714
0.204000000000000	-0.0121515604956809	-0.0907650210070482
0.205000000000000	-0.0120376697362555	-0.0900125246496902
0.206000000000000	-0.0119251168218865	-0.0892671961416671
0.207000000000000	-0.0118138788321070	-0.0885289395568130
0.208000000000000	-0.0117039333577881	-0.0877976605747640
0.209000000000000	-0.0115952584871805	-0.0870732664495461
0.210000000000000	-0.0114878327923870	-0.0863556659789179
0.211000000000000	-0.0113816353162862	-0.0856447694743391
0.212000000000000	-0.0112766455598486	-0.0849404887315256
0.213000000000000	-0.0111728434698845	-0.0842427370017944
0.214000000000000	-0.0110702094271499	-0.0835514289637984
0.215000000000000	-0.0109687242348541	-0.0828664806961506
0.216000000000000	-0.0108683691074982	-0.0821878096503347
0.217000000000000	-0.0107691256600819	-0.0815153346244555
0.218000000000000	-0.0106709758976387	-0.0808489757373854
0.219000000000000	-0.0105739022050861	-0.0801886544035260
0.220000000000000	-0.0104778873373990	-0.0795342933081235
0.221000000000000	-0.0103829144100703	-0.0788858163830383
0.222000000000000	-0.0102889668898785	-0.0782431487831717
0.223000000000000	-0.0101960285859152	-0.0776062168631977
0.224000000000000	-0.0101040836408914	-0.0769749481549613
0.225000000000000	-0.0100131165227153	-0.0763492713452840
0.226000000000000	-0.00992311201629413	-0.0757291162541908
0.227000000000000	-0.00983405521561349	-0.0751144138137427
0.228000000000000	-0.00974593151601590	-0.0745050960471301
0.229000000000000	-0.00965872660674158	-0.0739010960483815
0.230000000000000	-0.00957242646365315	-0.0733023479623525
0.231000000000000	-0.00948701734220049	-0.0727087869652345
0.232000000000000	-0.00940248577057295	-0.0721203492454291
0.233000000000000	-0.00931881854305614	-0.0715369719848446
0.234000000000000	-0.00923600271357899	-0.0709585933405456
0.235000000000000	-0.00915402558944712	-0.0703851524268383
0.236000000000000	-0.00907287472524817	-0.0698165892976747
0.237000000000000	-0.00899253791693994	-0.0692528449294598
0.238000000000000	-0.00891300319609652	-0.0686938612042082
0.239000000000000	-0.00883425882432220	-0.0681395808930277
0.240000000000000	-0.00875629328782052	-0.0675899476399782
0.241000000000000	-0.00867909529211903	-0.0670449059462736
0.242000000000000	-0.00860265375691938	-0.0665044011546775
0.243000000000000	-0.00852695781113077	-0.0659683794344570
0.244000000000000	-0.00845199678799509	-0.0654367877664318
0.245000000000000	-0.00837776022037649	-0.0649095739284173
0.246000000000000	-0.00830423783616755	-0.0643866864809601
0.247000000000000	-0.00823141955382311	-0.0638680747533941
0.248000000000000	-0.00815929547800941	-0.0633536888300817
0.249000000000000	-0.00808785589538746	-0.0628434795370904
0.250000000000000	-0.00801709127047940	-0.0623373984289348
0.260000000000000	-0.00734458936040902	-0.0574934753766819
0.270000000000000	-0.00673027337407894	-0.0530140257398649
0.280000000000000	-0.00616700360366077	-0.0488608296505054
0.290000000000000	-0.00564875061257291	-0.0450006667476700
0.300000000000000	-0.00517038928233473	-0.0414045481841289
0.310000000000000	-0.00472753674861788	-0.0380470819263128
0.320000000000000	-0.00431642375261702	-0.0349059459244114
0.330000000000000	-0.00393379168193894	-0.0319614489409017
0.340000000000000	-0.00357680954148210	-0.0291961629125158
0.350000000000000	-0.00324300651775919	-0.0265946139316837
0.360000000000000	-0.00293021684113946	-0.0241430214652910
0.370000000000000	-0.00263653441955159	-0.0218290774293940
0.380000000000000	-0.00236027529098241	-0.0196417583278178
0.390000000000000	-0.00209994637379234	-0.0175711649274630
0.400000000000000	-0.00185421932151670	-0.0156083849549488
0.420000000000000	-0.00140195261313789	-0.0119748593561939
0.440000000000000	-0.000995388348670228	-0.00868552610243735
0.460000000000000	-0.000627975171959831	-0.00569445717596784
0.480000000000000	-0.000294350798958730	-0.00296344160904646
0.500000000000000	9.91497574892494e-06	-0.000460448455950806
0.520000000000000	0.000288513603335260	0.00184156070196094
0.540000000000000	0.000544545056844323	0.00396555819599070
0.560000000000000	0.000780631332099167	0.00593117965473484
0.580000000000000	0.000999004853954855	0.00775530315558001
0.600000000000000	0.00120157801481041	0.00945251276562296
0.620000000000000	0.00138999837068874	0.0110354723319408
0.640000000000000	0.00156569282347637	0.0125152290202260
0.660000000000000	0.00172990326513948	0.0139014614362099
0.680000000000000	0.00188371554471058	0.0152026837109650
0.700000000000000	0.00202808317022127	0.0164264143516805
0.720000000000000	0.00216384682703648	0.0175793167157907
0.740000000000000	0.00229175054787245	0.0186673164902997
0.760000000000000	0.00241245518477176	0.0196957004281509
0.780000000000000	0.00252654969313008	0.0206691997225849
0.800000000000000	0.00263456063069420	0.0215920607239719
0.800000000000000	0.00263456063069420	0.0215920607239719
0.900000000000000	0.00309834138169736	0.0255683810055187
1	0.00346436407185387	0.0287217262879236
1.10000000000000	0.00376051108674813	0.0312824373482340
1.20000000000000	0.00400499220685795	0.0334024525123198
1.30000000000000	0.00421020097272207	0.0351859793432519
1.40000000000000	0.00438486350018432	0.0367068376099217
1.50000000000000	0.00453530074160971	0.0380187646277510
end

sort sigma

gen MPG_est = -0.0121
gen MPG_est_LB = MPG_est - 0.0034*1.96
gen MPG_est_UB = MPG_est + 0.0034*1.96


gen MPG_highgiving = -0.28


set scheme s2mono, permanently
#delimit;
			twoway 	( line kappanorway sigma if sigma<=1.1 & sigma>0.024, lcolor(blue)  lpattern(solid) ) 
					( line kappahigh sigma if sigma>0.062 & sigma<=1.1, lcolor(orange%70)  lpattern(solid) lwidth(thick)     ) 
					/*( line MPG_est sigma  if sigma < 0.76, lcolor(orange%70)  lpattern(dash) lcolor(gray%40)    ) 
					( rarea MPG_est_UB MPG_est_LB sigma if sigma < 0.76, lcolor(white%0)   color(gray%20)    ) 
					( scatteri -0.012 0.11 if sigma<=1.1, msymbol(o) color(gray%40) msize(medsmall)  ) */
					( scatteri -0.2784 0.086 if sigma<=1.1, msymbol(o) color(orange) msize(medium)   )
					,
					graphregion(color(white))
					ylabel(-0.4(0.1)0.2 , /*glcolor(gs15) gmax gmin*/ nogrid)
					xlabel(0(0.25)1.10, nogrid glcolor(gs15))
					plotregion(margin(miniscule))
					xmtick(0(0.05)1.10)
					legend( subtitle("{stSerif:Simulated MPG}", placement(west))
							order( 
									1 "{&kappa} {stSerif:calibrated to empirical setting}"
									2 "{&kappa} {stSerif:calibrated to 5% of gross income}"
									 )
									 symxsize(*0.75)
						   rows(4) cols(1) size(medsmall) region(color(white%0) ) ring(0) pos(11) margin(0 3 0 0) bmargin(10 0 0 0) )
				
					/*text(  -0.012 0.75 "{stSerif: Empirical MPG estimate}", place(e) color(gray) size(small)  )
					text(  -0.026 0.11 "{&sigma} {stSerif:= 0.11}", place(e) color(gray%40) size(small)   )*/
					text(  -0.2784 0.086 "{stSerif: MPG = -0.2784 when  {&sigma} = 0.0815}", place(e) color(orange) size(small)  )
					xtitle("{stSerif:Elasticity of Intertemporal Substitution,  {&sigma}}")
					ytitle("{stSerif:MPG out of wealth taxes}")
					
					xline(0.086, lcolor(gray%40) lwidth(medthick))
					/*subtitle("{stSerif:`title'}", color(black))*/;
			#delimit cr
graph export ${outputfilepath}/wdon1_calibration_MPG_different_kappas.pdf, as(pdf) replace

